SIP ladder

This endpoint returns the complete SIP signaling for a single call as JSON. The response includes every SIP message exchanged between Live Hub and the external SIP connection, in order, with the full text of each message.

Use it to trace call signaling or create custom call-flow visualizations.

Endpoint

GET /api/v1/calls/{callId}/sipLadder

Path parameters

Parameter Type Description
callId string UUID of the call.

Query parameters

Parameter Type Description
format string Format of the returned ladder. json (default) returns it as a JSON object.

Request

GET /api/v1/calls/82c6d362-d68b-4c6f-8136-1739323379e7/sipLadder?format=json HTTP/1.1
Host: livehub.audiocodes.io
Authorization: Bearer {token}

Response

200 OK — a JSON object with three branches: diagnosticInfo, nodes and messages.

diagnosticInfo identifies the session:

Property Type Description
sid string Global Session ID of the SIP session.

nodes is the list of elements the messages traveled between. A message refers to a node by its index in this array:

Property Type Description
displayName string IP address and port of the remote source or destination of the messages.
system boolean true when the node represents the system.

messages is the signaling itself, in order:

Property Type Description
timestamp string When the message was sent or received, in RFC 3339 UTC, for example 2012-04-23T18:25:43.511Z.
fromNode number Index of the sending element in the nodes array.
toNode number Index of the receiving element in the nodes array.
direction string Incoming or Outgoing.
transport string Transport type: UDP, TCP or TLS.
method string SIP method of a request, or the status code of a response.
sdp boolean true when the message carries SDP.
text string The message itself, SIP headers and SDP included.
{
  "diagnosticInfo": {
    "sid": "9c403:16:764823"
  },
  "nodes": [
    {
      "displayName": "185.246.41.140:5061"
    },
    {
      "displayName": "System",
      "system": true
    }
  ],
  "messages": [
    {
      "timestamp": "2022-12-11T15:12:40.924Z",
      "direction": "Incoming",
      "fromNode": 0,
      "toNode": 1,
      "transport": "TLS",
      "method": "INVITE",
      "sdp": true,
      "text": "INVITE sip:+13159611252@20.79.227.48:5071;transport=tls SIP/2.0\r\nRecord-Route: sip:185.246.41.140:5061;transport=tls;r2=on;lr;ftag=jrKcU67yFv75g\r\nRecord-Route: sip:10.31.224.10:5061;transport=tls;r2=on;lr;ftag=jrKcU67yFv75g\r\nRecord-Route: sip:10.31.9.8:6051;transport=tls;r2=on;lr;tnx=9e1.2e2\r\nRecord-Route: sip:10.31.9.8:6050;r2=on;lr;tnx=9e1.2e2\r\nVia: SIP/2.0/TLS 185.246.41.140:5061;branch=z9hG4bKc503.7e8f4968b5aa33da11b8d88187c40fba.0;i=fbe97\r\nVia: SIP/2.0/TLS 10.31.9.8:6051;rport=38331;branch=z9hG4bKc503.bd75d995e548e42302ca881853779e52.0\r\nVia: SIP/2.0/UDP 10.13.86.4:6000;received=10.13.86.4;rport=6000;branch=z9hG4bK2e519U2BcFy0S\r\nMax-Forwards: 66\r\nFrom: \"+197239764943\" sip:+197239764943@sip.telnyx.eu;tag=jrKcU67yFv75g\r\nTo: sip:+13159611252@10.31.9.8\r\nCall-ID: fdbd24f7-4065-435e-8a3c-54502596aee2\r\nCSeq: 60831988 INVITE\r\nContact: sip:mod_sofia@10.13.86.4:6000\r\nAllow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REFER, NOTIFY\r\nSupported: timer, path\r\nAllow-Events: talk, hold, conference, refer\r\nPrivacy: none\r\nContent-Type: application/sdp\r\nContent-Disposition: session\r\nContent-Length: 1341\r\nX-Telnyx-Session-ID: 41477678-7966-11ed-87a3-02420a0de468\r\nX-Telnyx-Leg-ID: 414c0076-7966-11ed-b7c0-02420a0de468\r\nP-Asserted-Identity: \"+197239764943\" sip:+197239764943@sip.telnyx.com;verstat=No-TN-Validation\r\n\r\nv=0\r\no=Telnyx 1670753618 1670753619 IN IP4 64.16.226.19\r\ns=Telnyx\r\nc=IN IP4 64.16.226.19\r\nt=0 0\r\nm=audio 17942 RTP/SAVP 0 8 18 101\r\na=rtpmap:0 PCMU/8000\r\na=rtpmap:8 PCMA/8000\r\na=rtpmap:18 G729/8000\r\na=fmtp:18 annexb=no\r\na=rtpmap:101 telephone-event/8000\r\na=fmtp:101 0-15\r\na=sendrecv\r\na=rtcp:17943 IN IP4 64.16.226.19\r\na=crypto:1 AEAD_AES_256_GCM_8 inline:EPoHqiWBn1Ag6jaORHiaBpYobBqvkNj4ZrwkzJQ5ycrmhTqzZPwZG6Rs9iE=\r\na=crypto:2 AEAD_AES_256_GCM inline:O8gM3wi+Oxat4g5/TsJq3rpMtkVDhV21fwpCEtOgqfCBT5HYq8AggfiD5Hs=\r\na=crypto:3 AEAD_AES_128_GCM_8 inline:Ag63ANdZf8/wJ3Uzx5DPqr3QvtchmOXF2Adx/g==\r\na=crypto:4 AEAD_AES_128_GCM inline:UtRWEXu9Zxe2nHb3zlUEDRFZ3lzA7d++A9yudw==\r\na=crypto:5 AES_256_CM_HMAC_SHA1_80 inline:sNeP0bWmfKjGQr7kcz/RFmszQVZ8+9OSYaqFw3ChU9c5//ZDfhZlFHDeMrlxRQ==\r\na=crypto:6 AES_192_CM_HMAC_SHA1_80 inline:xTyRoway4vVzBjTmYFV2AqDi+kVw95r0BoxFd7d48MtteQDCfvg=\r\na=crypto:7 AES_CM_128_HMAC_SHA1_80 inline:zM2BQty9SCjtMSlZt/MVR6GWwrp/0Lj9fKyy1y2q\r\na=crypto:8 AES_256_CM_HMAC_SHA1_32 inline:0ghpjJVaM8X1fcdEvTD39lDMncyKkC8XBNi4MF4toeXo3ZloyyaPm87OWYARZQ==\r\na=crypto:9 AES_192_CM_HMAC_SHA1_32 inline:4SpbZlyjEokhF/ly/B3KOvM4yGXSgTKSmbm7BkM6oeoi++PCedc=\r\na=crypto:10 AES_CM_128_HMAC_SHA1_32 inline:HnwgXDknriOrLxAWiA53mh63hJAVLYfbvRtcDMN6\r\na=crypto:11 AES_CM_128_NULL_AUTH inline:zgjH9VZp0tCukdEUQI1hTrm87n3AyVjGVBLnf2Lx\r\na=ptime:20"
    },
    {
      "timestamp": "2022-12-11T15:12:40.925Z",
      "direction": "Outgoing",
      "fromNode": 1,
      "toNode": 0,
      "transport": "TLS",
      "method": "100",
      "sdp": false,
      "text": "SIP/2.0 100 Trying\r\nVia: SIP/2.0/TLS 185.246.41.140:5061;i=fbe97;branch=z9hG4bKc503.7e8f4968b5aa33da11b8d88187c40fba.0\r\nVia: SIP/2.0/TLS 10.31.9.8:6051;rport=38331;branch=z9hG4bKc503.bd75d995e548e42302ca881853779e52.0\r\nVia: SIP/2.0/UDP 10.13.86.4:6000;received=10.13.86.4;rport=6000;branch=z9hG4bK2e519U2BcFy0S\r\nFrom: \"+197239764943\" sip:+197239764943@sip.telnyx.eu;tag=jrKcU67yFv75g\r\nTo: sip:+13159611252@10.31.9.8\r\nCall-ID: fdbd24f7-4065-435e-8a3c-54502596aee2\r\nCSeq: 60831988 INVITE\r\nContent-Length: 0"
    },
    {
      "timestamp": "2022-12-11T15:12:42.013Z",
      "direction": "Outgoing",
      "fromNode": 1,
      "toNode": 0,
      "transport": "TLS",
      "method": "180",
      "sdp": false,
      "text": "SIP/2.0 180 Ringing\r\nVia: SIP/2.0/TLS 185.246.41.140:5061;i=fbe97;branch=z9hG4bKc503.7e8f4968b5aa33da11b8d88187c40fba.0\r\nVia: SIP/2.0/TLS 10.31.9.8:6051;rport=38331;branch=z9hG4bKc503.bd75d995e548e42302ca881853779e52.0\r\nVia: SIP/2.0/UDP 10.13.86.4:6000;received=10.13.86.4;rport=6000;branch=z9hG4bK2e519U2BcFy0S\r\nFrom: \"+197239764943\" sip:+197239764943@sip.telnyx.eu;tag=jrKcU67yFv75g\r\nTo: sip:+13159611252@10.31.9.8;tag=1c22447708\r\nCall-ID: fdbd24f7-4065-435e-8a3c-54502596aee2\r\nCSeq: 60831988 INVITE\r\nContact: sip:20.79.227.48:5071;transport=tls\r\nRecord-Route: sip:185.246.41.140:5061;transport=tls;r2=on;lr;ftag=jrKcU67yFv75g\r\nRecord-Route: sip:10.31.224.10:5061;transport=tls;r2=on;lr;ftag=jrKcU67yFv75g\r\nRecord-Route: sip:10.31.9.8:6051;transport=tls;r2=on;lr;tnx=9e1.2e2\r\nRecord-Route: sip:10.31.9.8:6050;r2=on;lr;tnx=9e1.2e2\r\nServer: AudioCodes Live Hub/v.7.40BY.260.019\r\nContent-Length: 0"
    }
  ]
}